+++ /dev/null
-V0_1_0 {
- global:
- babl_component;
- babl_component_new;
- babl_conversion_get_destination_space;
- babl_conversion_get_source_space;
- babl_conversion_new;
- babl_cpu_accel_get_support;
- babl_exit;
- babl_fast_fish;
- babl_fish;
- babl_format;
- babl_format_exists;
- babl_format_get_bytes_per_pixel;
- babl_format_get_model;
- babl_format_get_n_components;
- babl_format_get_space;
- babl_format_get_type;
- babl_format_has_alpha;
- babl_format_is_format_n;
- babl_format_is_palette;
- babl_format_n;
- babl_format_new;
- babl_format_with_space;
- babl_free;
- babl_get_name;
- babl_get_user_data;
- babl_get_version;
- babl_icc_make_space;
- babl_icc_get_key;
- babl_init;
- babl_introspect;
- babl_malloc;
- babl_model;
- babl_model_new;
- babl_new_palette;
- babl_palette_reset;
- babl_palette_set_palette;
- babl_process;
- babl_process_rows;
- babl_sampling;
- babl_set_user_data;
- babl_space;
- babl_space_from_xyz;
- babl_space_get_rgbtoxyz;
- babl_space_to_xyz;
- babl_ticks;
- babl_type;
- babl_type_new;
- babl_space_to_icc;
- babl_db_exist_by_name;
- babl_db_find;
- babl_db_init;
- babl_db_exist_by_id;
- babl_db_each;
- babl_formats_count;
- babl_format_class_for_each;
- babl_model_class_for_each;
- babl_type_class_for_each;
- babl_conversion_class_for_each;
- babl_set_extender;
- babl_extension_quiet_log;
- babl_fish_path;
- babl_extender;
- babl_class_name;
- babl_sanity;
- babl_type_is_symmetric;
- babl_model_is_symmetric;
- babl_fish_db;
- babl_polynomial_approximate_gamma;
- babl_backtrack;
-
- local:
- *;
-};
bablInclude = include_directories('.')
subdir('base')
+version_script = 'babl.map'
+export_symbols = join_paths(meson.source_root(), 'export-symbols')
+version_script_target = custom_target(version_script,
+ input : [ export_symbols, ] ,
+ output: [ version_script ] ,
+ command: [
+ 'python',
+ join_paths(meson.source_root(), 'gen_babl_map.py'),
+ export_symbols,
+ version_script,
+ ],
+ capture: true,
+)
+
+
# Linker arguments
babl_link_args = [
'-Wl,--version-script,' + version_script,
link_whole: [ babl_base, ],
link_args: [ babl_link_args, ],
dependencies: [ math, thread, dl, ],
+ link_depends: [ version_script_target, ],
version: so_version,
install: true,
)
--- /dev/null
+import sys
+
+export_symbols=sys.argv[1]
+version_file=sys.argv[2]
+
+with open(export_symbols, 'r') as syms, \
+ open(version_file, 'w') as version:
+ version.write("V0_1_0 {\n global:\n")
+ for sym in syms:
+ version.write(" {};\n".format(sym.strip()))
+ version.write(" local:\n *;\n};\n")
# Subdirs
rootInclude = include_directories('.')
-version_script = join_paths(meson.current_source_dir(), 'babl.map')
subdir('babl')
subdir('extensions')